/*
 * @Descripttion: 
 * @version: 
 * @Author: Eugene
 * @Date: 2023-12-31 13:49:55
 * @LastEditors: Andy
 * @LastEditTime: 2024-05-04 14:46:31
 */
/*
____/\\\\\\\\\_____        __/\\\________/\\\_        __/\\\\\\\\\\\_
 __/\\\///////\\\___        _\/\\\_______\/\\\_        _\/////\\\///__
  _\/\\\_____\/\\\___        _\/\\\_______\/\\\_        _____\/\\\_____
   _\/\\\\\\\\\\\/____        _\/\\\_______\/\\\_        _____\/\\\_____
    _\/\\\//////\\\____        _\/\\\_______\/\\\_        _____\/\\\_____
     _\/\\\____\//\\\___        _\/\\\_______\/\\\_        _____\/\\\_____
      _\/\\\_____\//\\\__        _\//\\\______/\\\__        _____\/\\\_____
       _\/\\\______\//\\\_        __\///\\\\\\\\\/___        __/\\\\\\\\\\\_
        _\///________\///__        ____\/////////_____        _\///////////__
*/
#ifndef RUI_ROOT_INIT_H
#define RUI_ROOT_INIT_H
#include "main.h"
#include "stdint.h"
#include "RUI_MATH.h"
#include "MY_define.h"
#include "RUI_DBUS.h"
#include "usart.h"
#include "bsp_dwt.h"
#include "DJI_Motor.h"
#include "DM_Motor.h"
#include "Motors.h"

//在定时器调用这一个函数即可
void RUI_F_ROOT(RUI_ROOT_STATUS_Typedef *Root, MOTOR_Typdef *MOTOR);
//电机在线监测
uint8_t DJI_F_MOTOR_STATUS(DJI_MOTOR_DATA_Typedef* DATA);
uint8_t DM_F_MOTOR_STATUS(DM_MOTOR_DATA_Typdef* DATA);
//总的状态监测
void RUI_F_ROOT_ALL_STATUS(RUI_ROOT_STATUS_Typedef *Root, MOTOR_Typdef *MOTOR);
//主控位置判断
uint8_t RUI_F_MASTER_LOCATION_JUDGE(RUI_ROOT_STATUS_Typedef *Root);
//主控通信
//uint8_t RUI_F_MASTER_COMMUNICATION(void);
//LED
void RUI_F_LED(uint8_t COLOR , int TIME);
void RUI_F_LED_SHOW_STATUS(RUI_ROOT_STATUS_Typedef *Root);
#endif

